import request from '@/utils/request';

export function fetchOrchards() {
  return request({
    url: '/api/orchards',
    method: 'get'
  });
}

export function createOrchard(data) {
  return request({
    url: '/api/orchards',
    method: 'post',
    data
  });
}

export function updateOrchard(id, data) {
  return request({
    url: `/api/orchards/${id}`,
    method: 'put',
    data
  });
}

export function deleteOrchard(id) {
  return request({
    url: `/api/orchards/${id}`,
    method: 'delete'
  });
}